# -*- coding: utf-8 -*-
from django.contrib.sites.managers import CurrentSiteManager
from datetime import datetime

class CurrentSitePublishedManager(CurrentSiteManager):
    """Manager for ready to be published objects on the current site. 
    This is assuming #7154 is fixed for the non abstract models"""
    def get_query_set(self):
        queryset = super(CurrentSitePublishedManager, self).get_query_set()
        return queryset.filter(publish_date__lte=datetime.now()).filter(status__exact='P')

